Don't require tex-mode or texnfo-upd.
authorRichard M. Stallman <rms@gnu.org>
Sun, 16 May 1993 21:11:54 +0000 (21:11 +0000)
committerRichard M. Stallman <rms@gnu.org>
Sun, 16 May 1993 21:11:54 +0000 (21:11 +0000)
(texinfo-mode-map): Binding for " deleted.
(texinfo-tex-print): Require tex-mode here.
(texinfo-tex-region): Likewise.

lisp/textmodes/texinfo.el

index 5f502fb85d5219af86ce4eb0574ba731bc2b63f1..32e99785e6b43c66fa682c5bd37c711d8715c345 100644 (file)
@@ -24,8 +24,8 @@
 
 ;;; Code:
 
-(require 'texnfo-upd)
-(require 'tex-mode)
+;;; Don't you dare insert any `require' calls in this file--rms.
+
 (defvar texinfo-mode-syntax-table nil)
 
 (if texinfo-mode-syntax-table
@@ -67,7 +67,7 @@
 
   (define-key texinfo-mode-map "\C-c\C-s"     'texinfo-show-structure)
 
-  (define-key texinfo-mode-map "\""           'tex-insert-quote)
+;;;  (define-key texinfo-mode-map "\""           'texinfo-insert-quote)
   (define-key texinfo-mode-map "\C-c}"          'up-list)
   (define-key texinfo-mode-map "\C-c{"          'texinfo-insert-braces)
 
   (define-key texinfo-mode-map "\C-c\C-cd"    'texinfo-insert-@dfn)
   (define-key texinfo-mode-map "\C-c\C-cc"    'texinfo-insert-@code))
 
+;;; I turned this off because it is inconvenient.
+;;; The real " character is used often in texinfo files.  --rms.
+;;;(defun texinfo-insert-quote (arg)
+;;;  "Insert the appropriate quote marks for TeX.
+;;;Inserts the value of `tex-open-quote' (normally ``) or `tex-close-quote'
+;;;\(normally '') depending on the context.  With prefix argument, always
+;;;inserts \" characters."
+;;;  (interactive "*P")
+;;;  (if arg
+;;;      (self-insert-command (prefix-numeric-value arg))
+;;;    (insert
+;;;     (cond ((or (bobp)
+;;;            (save-excursion
+;;;              (forward-char -1)
+;;;              (looking-at "\\s(\\|\\s \\|\\s>")))
+;;;        tex-open-quote)
+;;;       ((= (preceding-char) ?\\)
+;;;        ?\")
+;;;       (t
+;;;        tex-close-quote)))))
+
 (defun texinfo-insert-@var ()
   "Insert the string @var in a texinfo buffer."
   (interactive)
@@ -328,6 +349,7 @@ between the strings defined by `tex-start-of-header' and `tex-end-of-header'
 inclusive.  The header must start in the first 100 lines.  The value of
 tex-trailer is appended to the temporary file after the region."
   (interactive "r")
+  (require 'tex-mode)
   (if (get-buffer "*tex-shell*")
       (tex-kill-job)
     (tex-start-shell))
@@ -411,6 +433,7 @@ See \\[texinfo-tex-region] for more information."
   "Print .dvi file made by \\[texinfo-tex-region] or \\[texinfo-tex-buffer].
 Runs the shell command defined by `tex-dvi-print-command'."
   (interactive)
+  (require 'tex-mode)
   (send-string "tex-shell"
               (concat tex-dvi-print-command
                        " " tex-zap-file ".dvi" "\n"))